<div class="blade-content ng-scope" id="blade-content">
  <div class="blade-inner">
    <div class="inner-block">
      <form name="form" class="form" (submit)="onCreate()" [formGroup]="formGroup" novalidate>
        <div class="blade-static __bottom" *ngIf="currentBlade.isNew">
          <button class="btn" [disabled]="!formGroup.valid">创建</button>
        </div>

        <div class="column">      
          <div class="form-group">
            <label class="form-label">风场</label>
            <div class="form-input">
              <select name="farmId" class="chosen-select" formControlName="farmId">
                <option [value]="item.farmId" *ngFor="let item of farms">                  
                  {{item.farmName}}
                </option>
                <!--<option value="21">21</option>
                <option value="88">88</option>
                <option value="3">3</option>
                <option value="4">4</option>-->
              </select>
            </div>
            <div *ngIf="formErrors.farmId" class="form-error">
              {{ formErrors.farmId }}
            </div>
          </div>
          <div class="form-group">
            <label class="form-label">工期代码</label>
            <div class="form-input">
              <input id="phaseCode" name="phaseCode" type="text" placeholder="输入工期代码" autocomplete="off" formControlName="phaseCode">
            </div>
            <div *ngIf="formErrors.phaseCode" class="form-error">
              {{ formErrors.phaseCode }}
            </div>
          </div>

          <div class="form-group">
            <label class="form-label">工期名称</label>
            <div class="form-input">
              <input id="farmCode" name="phaseName" type="text" placeholder="输入工期名称" autocomplete="off" formControlName="phaseName">
            </div>
            <div *ngIf="formErrors.phaseName" class="form-error">
              {{ formErrors.phaseName }}
            </div>
          </div>

          <div class="form-group">
            <label class="form-label">总装机容量(MW)</label>
            <div class="form-input">
              <input id="capacity" name="capacity" type="number" placeholder="输入总装机容量" autocomplete="off" formControlName="capacity">
            </div>
            <div *ngIf="formErrors.capacity" class="form-error">
              {{ formErrors.capacity }}
            </div>
          </div>

          <div class="form-group">
            <label class="form-label">风场建设日期</label>
            <div class="form-input">
              <input id="productionDate" name="productionDate" type="date" placeholder="输入键名称" autocomplete="off" formControlName="productionDate">
            </div>
            <div *ngIf="formErrors.productionDate" class="form-error">
              {{ formErrors.productionDate | date:"yyyy/MM/dd"}}
            </div>
          </div>

          <div class="form-group">
            <label class="form-label">排序</label>
            <div class="form-input">
              <input name="phaseSeq" formControlName="phaseSeq" placeholder="输入排序">
            </div>
            <div *ngIf="formErrors.phaseSeq" class="form-error">
              {{ formErrors.phaseSeq }}
            </div>
          </div>



        </div>

      </form>
    </div>
  </div>
</div>